﻿@model mBlog.ViewModels.PostView
@{
    ViewBag.Title = Model.Post.Title;
}
<div class="post">
    <h3>
        <a href="@Model.Post.Url">@Model.Post.Title</a>    
    </h3>
    <div class="entry">
        <p>
            @Model.Post.Content
        </p>
    </div>
    <ul class="postmetadata">
        <li class="icon_comment icon_r">
            @Model.Post.Comments.Count().ToString()&nbsp;条评论
        </li>
        <li class="icon_cat"><strong>分类:</strong>
            @foreach (var category in Model.Categories)
            {
                <a href="@category.Url">@category.Name</a>;
            }
        </li>
        <li class="icon_tag"><strong>标签:</strong>
            @foreach (var tag in Model.Tags)
            {
                <a href="@tag.Url">@tag.Name</a>;
            }
        </li>
    </ul>
    <script type="text/javascript" id="wumiiRelatedItems">
        var wumiiPermaLink = "@Model.Post.Url";  //请用代码生成文章永久的链接 
        var wumiiTitle = "@Model.Post.Title"; //请用代码生成文章标题
        @{
            System.Text.StringBuilder tags = new System.Text.StringBuilder();
            foreach (var tag in Model.Tags)
            {
                tags.Append(tag.Name).Append(",");
            }
        } 
        var wumiiTags = "@tags.ToString().TrimEnd(',')"; //请用代码生成文章标签，以英文逗号分隔，如："标签1,标签2"
        var wumiiSitePrefix = "http://fengqijun.com/";
    </script>
    <script type="text/javascript">
        var wumiiParams = "&num=3&mode=3&pf=JAVASCRIPT";
    </script>
    <script type="text/javascript" src="http://widget.wumii.com/ext/relatedItemsWidget.htm"></script>
        <a href="http://www.wumii.com/widget/relatedItems.htm" style="border:0;">
        <img src="http://static.wumii.com/images/pixel.png" alt="无觅相关文章插件，快速提升流量" style="border:0;padding:0;margin:0;" />
    </a>
    <br />
    @{Html.RenderPartial("_CommentList", Model.Post.Comments);}
    @{Html.RenderPartial("_AddComment", Model.AddComment);}
    
</div>
